static let id = 0;
<script>
  input.value()?.classList.add(`child${id++}`);
</script>